﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace SMS.Business.Customer
{
    public class CustomerTransactionsBusiness : BusinessBase<SMS.DAL.CutomerCreditTransaction, SMS.DAL.Providers.CustomerCreditTransSearch>
    {
        private SMS.DAL.Providers.CustomerCreditTransProvider Provider;
        public CustomerTransactionsBusiness()
        {
            Provider = new DAL.Providers.CustomerCreditTransProvider();
        }
        public override bool Insert(DAL.CutomerCreditTransaction item)
        {
            Provider.Insert(item);
            return true;
        }

        public override bool Update(DAL.CutomerCreditTransaction updatedItem)
        {
            Provider.Update(updatedItem);
            return true;
        }

        public override bool Delete(int id)
        {
            Provider.Delete(id);
            return true;
        }

        public override DAL.CutomerCreditTransaction GetByID(int id)
        {
            return Provider.GetByID(id);

        }

        public override List<DAL.CutomerCreditTransaction> Search(DAL.Providers.CustomerCreditTransSearch SearchCriteria)
        {
            return Provider.Search(SearchCriteria);
        }
    }
}
